import request from "@/utils/request";

// 查询优惠劵发放方式列表

// 单条 查询优惠劵发放方式详细
export function startRefund(id) {
  return request({
    url: "/coupon/issue/" + id,
    method: "get",
  });
}

// 申请退款信息
export function applyExaminRefund(data) {
  return request({
    url: "/station/order/applyExaminRefund",
    method: "post",
    data: data,
  });
}

// 撤回申请的信息
export function recallApplyRefund(data) {
  return request({
    url: "/station/order/recallApplyRefund",
    method: "post",
    data: data,
  });
}

// 审核通过
export function examinRefundSuccess(data) {
  return request({
    url: "/station/order/examinRefundSuccess",
    method: "post",
    data: data,
  });
}

// 审核驳回
export function examinRefundBack(data) {
  return request({
    url: "/station/order/examinRefundBack",
    method: "post",
    data: data,
  });
}
// // 修改优惠劵发放方式
// export function updateIssue(data) {
//   return request({
//     url: '/coupon/issue',
//     method: 'put',
//     data: data
//   })
// }

// // 删除优惠劵发放方式
// // export function delIssue(id) {
// //   return request({
// //     url: '/coupon/issue/' + id,
// //     method: 'delete'
// //   })
// // }

// // 导出优惠劵发放方式
// export function exportIssue(query) {
//   return request({
//     url: '/coupon/issue/export',
//     method: 'get',
//     params: query
//   })
// }

// 油机订单Order_Oil_Engine

// POST /engine/oilEngineSum 查询单个卡信息总和
export function oilEngineSum(data) {
  return request({
    url: "/engine/oilEngineSum",
    method: "post",
    data: data,
  });
}

// POST /engine/list 查询单个卡信息
export function oilEngineList(data, pageNum, pageSize) {
  return request({
    url: `/engine/list?pageNum=${pageNum}&pageSize=${pageSize}`,
    method: "post",
    data: data,
  });
}

// GET /engine/oilGun 油机订单数据下所有油枪
export function oilGun(query) {
  return request({
    url: "/engine/oilGun",
    method: "get",
    params: query,
  });
}

// GET /engine/oilName 油机订单数据下所有油品
export function oilName(query) {
  return request({
    url: "/engine/oilName",
    method: "get",
    params: query,
  });
}